
$( document ).ready(function() {
   		
	// Initialize sliders
	//$( "#slider" ).slider({min: 1, max: 100, animate: "fast", value: 0});
	$( "#slider" ).noUiSlider({range: [0, 100], start: 1, handles: 1, step: 1, slide: function() {
		
		$("#slider_value_meters").html(Math.round($("#slider").val()));
		$("#slider_value_feet").html(Math.round($("#slider").val() * 3.280839895));
		$("#wheel_submit_button").attr("disabled", false);
	}});
	
	$( "#slider_pie" ).noUiSlider({range: [0, 100], start: 1, handles: 1, step: 1, slide: function() {
	
		$("#slider_value_pie").html(Math.round($("#slider_pie").val()));
        $("#pie_submit_button").attr("disabled", false);
	}});
	
	
	$( "#slider_beer" ).noUiSlider({range: [0, 3000], start: 1, handles: 1, step: 1, slide: function() {
	
		$("#slider_value_grams").html(Math.round($("#slider_beer").val()));
		var x = Math.round($("#slider_beer").val()) * 0.00220462;
		x = Math.floor(x * 100) / 100;
		$("#slider_value_pounds").html(x.toFixed(2));
		
        $("#beer_submit_button").attr("disabled", false);
	}});

});
	

